﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace UM_SERVER.Command
{
    class InputCommand
    {
        public static void NotifyCommand()
        {
            Console.Write("命令 >");
            String Command = Console.ReadLine();
            if(Command != null)
            {
                CommandProtocol.Protocol CP = Globle.commandHelper.GetCommandProtocol(Command);
                ICommandParser Parser = Globle.commandHelper.FindParser(CP);
                if (Parser.Accpet(Command))
                {
                    Parser.ParserCommand(Command);
                }
                else
                {
                    ////////////////////////////////////////////////
                    ///                未知命令
                    ////////////////////////////////////////////////
                }
            }
            NotifyCommand();
        }
    }
}
